package com.dianhun.es.other;
import java.util.ArrayList;
import java.util.Scanner;
/**
 * @author cyt
 * @create 2020-08-28 下午 7:14
 */
public class test {

    static ArrayList<Integer> ans = new ArrayList<Integer>();
    static int result = 0;
    static int n, m;

    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        n = sc.nextInt();
        m = sc.nextInt();
        ArrayList<Integer> list = get(n);
        for (int anInt : list) {
            System.out.println(anInt);
        }
    }
    static void dfs() {

    }
    private static ArrayList<Integer> get(int n) {
        int k = 0;
        while (n > 0) {
            int temp = n % 10;
            ans.add(temp);
            n = n / 10;
        }
        return ans;
    }
}
